home *** CD-ROM | disk | FTP | other *** search
/ The 640 MEG Shareware Studio 2 / The 640 Meg Shareware Studio CD-ROM Volume II (Data Express)(1993).ISO / comm / cmdasp.zip / CMDASP.TXT
Text File  |  1992-03-15  |  6KB  |  118 lines

  1.  
  2.       PROCOMM .CMD SCRIPT FILE CONVERSION TO PROCOMM PLUS VERSION 2
  3.  
  4. Updating your Procomm 2.4.2 and 2.4.3 .CMD scripts to work with Procomm PLUS
  5. Version 2.0, is really a two-step process.  Before you start changing you
  6. scripts to bring them into Procomm PLUS Version 2.0 compatibility, please make
  7. a set of backups.  Failure to do this has caused untold grief for many.
  8.  
  9. First, the .CMD scripts used in Version 2.4.2 and 2.4.3 must be changed to the
  10. .ASP scripts used in Procomm PLUS 1.1.  From that point, utilities furnished
  11. with Version 2.0 will finish the job for us.  To see how we do this, let's use
  12. the material provided in the Version 1.1 User's Manual of that time.
  13.  
  14. Procomm 2.4.2 (and 2.4.3) used several "output translation characters" which
  15. Procomm PLUS does not support - the exclamation point (!, representing a
  16. carriage return) and the vertical bar (|, representing an escape).  In Procomm
  17. PLUS, use a Ctrl-M (^M) in place of the exclamation point to send a carriage
  18. return; use Ctrl-left bracket (^[) to send an escape.  The caret (^) for a
  19. control character and tilde (~) for a pause are still supported.
  20.  
  21. You can easily convert Procomm 2.4.2 (and 2.4.3) command files (*.CMD) to .ASP
  22. files:
  23.  
  24.                  Type RENAME *.CMD *.ASP, then press [ENTER].
  25.  
  26. Within the converted *.ASP files make the following two changes.  First, make
  27. sure that all command keywords are completely spelled out; Procomm PLUS does
  28. not support abbreviated keywords.  Second, change all the output translation
  29. characters as described above.
  30.  
  31. Finally, several script commands have changed:
  32.  
  33.   Change any occurrences in your script files of
  34.      SET BACKSPACE IN DEST|NONDEST
  35.   To
  36.      SET BACKSPACE DEST|NONDEST
  37.  
  38.   Change any occurrences of
  39.      SET CR_IN CR|CR_LF
  40.   To
  41.      SET CR CR|CR_LF
  42.  
  43.   Change any occurrences of
  44.      SET FLOWCTRL ON|OFF
  45.   To
  46.      SET SOFTFLOW ON|OFF
  47.  
  48.   Procomm 2.4.2's SET BACKSPACE OUT and SET CR_OUT are not supported by Procomm
  49. PLUS. Change the keyboard mapping (Press Alt-F8) to assign the output values
  50. for the [BACKSPACE] and [ENTER] keys.
  51.  
  52. That wasn't so bad, was it?
  53.  
  54. Now it is time to take these scripts converted from .CMD to .ASP and do a quick
  55. check or two on them.  Because Procomm PLUS Version 2.0 uses compiled scripts,
  56. and because the compiler (ASPCOMP.EXE) is a fussy little devil, some syntax
  57. errors you may have made in your older scripts can cause a problem.  Here are a
  58. few tips based on what I have seen on the Forum.  Many use the command DIAL 1
  59. to dial the Dialing Directory entry number 1.  Previously this sneaked by in
  60. many cases.  But the compiler requires the correct syntax, DIAL "1" (note the
  61. quotes).  Do be sure that all your comments within your converted .ASP scripts
  62. start with a semicolon (;).  A line which is only comments and contains no
  63. script commands should start with a semicolon.  And be sure your script ends
  64. with a "newline", that is, an ASCII 13 followed by an ASCII 10 for the cr/lf
  65. combination.  This is the correct way that a word processor (saving in ASCII
  66. mode) saves the file.  But if you have written your file with COPY CON you may
  67. have omitted this.  There should be no end-of-file character (Ctrl-Z) on the
  68. last command line, but rather on the line after the last line which contains a
  69. command.
  70.  
  71. I have seen on the Forum a couple of other things that cause problems.  Among
  72. these are mismatched IF/ENDIF, $IF/$ENDIF, SWITCH/ENDSWITCH, CASE/ENDCASE,
  73. DEFAULT/ENDCASE, FOR/ENDFOR, WHILE/ENDWHILE, and COMMENT/ENDCOMMENT
  74. statements.  It is best to get these squared away now.
  75.  
  76. That done, we are ready to use the CONVERT.EXE program that comes with Procomm
  77. PLUS Version 2.0 to convert these Procomm PLUS Version 1.1 .ASP scripts to the
  78. new format.  If they were already prepared as above when you used PCINSTAL to
  79. install Version 2.0, the scripts would have been automatically converted.  To
  80. do it manually, go to the directory containing CONVERT.EXE (which is on your
  81. distribution disk if you can't find it) and your newly upgraded .ASP scripts
  82. and enter CONVERT MYFILE.ASP for each of the .ASP files in turn.  This
  83. conversion process will write the new style .ASP file, and make a .BAK backup
  84. copy out of the old one.  When it converts it will correct for changes in
  85. syntax in most cases, and will also add PROC MAIN at the top of the script and
  86. ENDPROC at the end of the script.  Because we can now have all kinds of
  87. procedures, this is a sort of "label" that the compiler requires.  There will
  88. also be a header on the script saying it has been converted.  You might take a
  89. look at one to see just what this CONVERT.EXE actually does.
  90.  
  91. The next step is to "compile" the newly created new version .ASP file, using
  92. ASPCOMP.EXE, another of the files on your distribution disks.  The compiling
  93. actually makes an .ASX file from an .ASP script, and it is this .ASX script
  94. file that Procomm PLUS Version 2.0 actually uses.  It is a lot smaller than its
  95. equivalent .ASP file, and nobody can read it to see your Passwords, etc.  It
  96. runs much faster, too.
  97.  
  98. Although in some circumstances Procomm PLUS will compile the script for you "on
  99. the run", I suggest you do not use this system at first, since you miss a lot
  100. of error information.  Instead, do it at the DOS prompt.  Simply enter: ASPCOMP
  101. /ML MYFILE.ASP.  The /ML causes the compiler to write a .MAP file for the
  102. script which will help you find errors, should there be any.  In some cases it
  103. will even write an .ERR file to provide help in tracking down problems.
  104.  
  105. Remember that if you change an .ASP file for any reason, you must once again
  106. compile it using ASPCOMP so that the changes are reflected in the .ASX file
  107. actually used as a script by Procomm PLUS Version 2.0.
  108.  
  109. Once everything is running properly you can delete the .BAK backup versions of
  110. your scripts, and the .MAP and .ERR files that the compiler may have written.
  111.  
  112. The Datastorm Forum is the place to get answers if you have any problems with
  113. these converted scripts.  Just give a holler and one of the SYSOPs or other
  114. users will be happy to give you a hand.  Welcome to Version 2!
  115.  
  116.  
  117.  
  118.